package com.example.cslp.controller;


import com.example.cslp.pojo.entity.Mail;
import com.example.cslp.service.MailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

public class MailController {
    @Autowired
    MailService mailService;
    @ResponseBody
    @RequestMapping("/mail")
    public String sendSimpleMail(Mail mail){
        mailService.sendSimpleMailMessage(mail);
        return "邮件发送成功";
    }
}
